package org.springframework.webflow.wanda;

import java.io.Serializable;
import java.util.List;
import java.util.Map;

import javax.faces.context.ExternalContext;
import javax.faces.context.FacesContext;

public class WandaUserModelBean implements Serializable {

    private static final long serialVersionUID = 1L;

    private WandaUser WandaUserToModify = null;

    public WandaUser getWandaUserToModify() {
	return WandaUserToModify;
    }

    public void setWandaUserToModify(WandaUser WandaUserToModify) {
	this.WandaUserToModify = WandaUserToModify;
    }

    public List<WandaUser> listWandaUsers(WandaUserService WandaUserService) {
	List<WandaUser> WandaUsers = WandaUserService.listWandaUsers();
	return WandaUsers;
    }

    public String selectWandaUserAction() {
	ExternalContext externalContext = FacesContext.getCurrentInstance().getExternalContext();
	Map requestMap = externalContext.getRequestMap();
	this.WandaUserToModify = (WandaUser) requestMap.get("customer");
	return "selectWandaUserAction";
    }

}
